package com.edu.controller.service.impl;

import com.edu.controller.mapper.UserMapper;
import com.edu.controller.model.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service
public class UserServiceImpl {
    @Autowired
    private UserMapper mapper;

    @Transactional(readOnly = true)
    public User findUserById(Long id){
        return mapper.selectByPrimaryKey(id);
    }

}
